home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 1
/
Cream of the Crop 1.iso
/
UTILITY
/
FILES15.ARJ
/
FILES.DOC
next >
Wrap
Text File
|
1991-02-25
|
9KB
|
201 lines
files - List Files 25-Feb-91
Syntax:
files [path] [options]
Options:
+directory - display directories instead of files.
+all - display both directory files and regular files
s=key - specify how the directory entries are to be sorted. key may
be no[ne], na[me], d[date], or s[ize].
+current - only display files at the current level. By default, files
will traverse any subdirectories that it finds.
+modified - only display files which have the "modified" (or "archive")
bit set.
-sort - don't sort the file names. This is equivalent to s=none.
-verbose - display only the name of the file, one file per line
+verbose - adds file attriubutes to the default display, one file per
line.
+totals_only - suppresses the information about individual files. Only the
totals are displayed.
+Before - changes the date/time matching from files >= to the user's
date/time to files <= the user's date/time.
p=pattern - display only those files whose names match this pattern.
This option is included for compatibility with the QNX
version of this utility, and to allow the user specify
more than one file name to search for. Note that only a
filename may be specified, not a complete path.
d=[dd-mmm-yy]- display only those files whose date is >= to this date. Note
that d= implies the current date. The absense of a t=
specification implies a time of 00:00:00.
d=([-]#days) - specifies a number of days relative to today. This may be
positive or negative.
t=hh:mm[:ss] - Modifies the time associated with the d= specification. Note
that in the absense of a d= specification, the current date
is assumed.
+1 - forces a single column display of file names, rather than the
two filenames per line which is the default when only a
single directory is being displayed.
+Date_sort - sorts the files by date, rather than by name.
+Mkdir - display mkdir commands to re-create the specified directory
tree.
+Subtotals - diplays the number of files, and the total number of bytes
on a directory by directory basis.
+pause - pauses at the end of each page displayed, requiring that the
user press return to continue.
-pause - overrides the default of pausing during the help display
+help - generates the help display. -help and ? will also generate
the help display.
Description:
The FILES command allows the user to list the files at or below any point in
the file structure. If no path is specified, then the current disk/directory
is assumed. The FILES command will walk the entire tree structure recursively,
displaying all files at the specified (or current) directory, followed by
all files at lower levels. The +current option prevents the recursive walk
of the file "tree", causing only those files at the current level to be
displayed.
Normally, the names of the files within a directory will be sorted by file name
before being displayed, and the directories will be sorted also. This feature
can be turned off by specifying the -sort option (or s=none), in which case
the file names and directories will be displayed in the order that they are
found. When sorting, files at the current directory will be displayed first,
followed by any files at lower levels.
The s=key option allows the user to specify alternative sort keys. The files
within a directory name be sorted by name (s=name), date (s=date), size
(s=size), or not sorted (s=none). The +Date_sort option is equivalent to
s=date.
The FILES command will not normally print the names of directories. If the
user wishes to examine directories which exist at this and lower levels, the
+directory option will enable the display of directory names, and will suppress
the display of normal file names. The -sort and +current options apply to
directories as well as normal files. The d= and t= options also apply.
Normally the FILES utility will display either regular file names, or directory
file names, but not both at once. The +all switch overrides this behavior.
Directory files are preceded by a '+', and regular files are preceded by a
blank.
The default display shows file size, file date, and file name. Two files are
displayed per line. Whenever a filename is preceded by a directory name,
only one filename is displayed per line.
Pattern Matching:
If desired, only files whose name matches a pattern will be displayed. The
pattern is typically specified as part of the path, but it also may be specified
using the p= option. A pattern may be any valid filename, and may include any
of the following wildcards:
* matches any run of characters
? matches any single character
[a-z] matches any character, 'a'- 'z'
[az] matches either an 'a' or a 'z'
*a*.doc matches any ".doc" file which contains an 'a' prior to the period
Note that this form of pattern matching is considerable different
that what is provided under MS-DOS. Under MS-DOS, a '*'
automatically assumes the remainder of the field. Thus "*" and
"*a*" are equivalent when using MS-DOS's pattern matching.
The pattern may be prefixed by a a '^' character, which indicates to match on
any file which does NOT match the pattern. For example, specifying "^*.c"
will match all files which do not end in ".c". Likewise, a '^' may be
specified as the first character inside the [] pair. This specifies that
any character which does not match those specified is acceptable.
A filename which does not contain an extention may be specified as "filename",
"filename.", or "filename.*".
A '*' at of a pattern will match any run of characters. Thus "pattern*" is
equivalent to "pattern*.*".
Up to 10 patterns may be specified.
The +verbose switch can be used to display extended information for each file in
the directory. For MS-DOS, the following information will be presented:
a ARCHIVE. The file has been modified.
s SYSTEM. The file is a system file.
h HIDDEN. The file is hidden.
r READ-ONLY. The file cannot be modfied.
v VOLUME-ID. The file is a volume id. (this bit is not currently displayed).
Examples:
files +c
This will print the names, size, and time/date of the files in the current
directory only.
files c:\msc p=*.h
files c:\msc\*.h
These commands will print the names of any file that matches the pattern
"*.h" in the directory tree that begins at "c:\msc".
files c: +v
This command will generate a listing of all of the files on the C: disk.
files c:*.exe p=*.com p=*.bat
This command will locate all of the "executable" files on the C: disk.
files c: d=21-Jun-88
This command will locates all of the files on the C: disk which were
created/modified on or after 21-Jun-88.
files c: d=21-Jun-88 +Before
This command will locates all of the files on the C: disk which were
created/modified before 21-Jun-88.
files d=
This command will locates all of the files in the current directory which
were created/modified today.
files d=(1)
This command will locates all of the files in the current directory which
were created/modified one day past today. This is useful for locating
files which were created when the date was not set.
files d=(-5)
This command will locates all of the files in the current directory which
were created/modified in the last 6 days (today or the preceding 5 days).
files c: +modified >modified.lst
This command will locates all of the files on the C: disk which were
created/modified since the last backup, and redirects the list to the
file "modified.lst" in the current directory.
NOTICE
This program has been released to the public domain by its
author. You may use it, modify it, and copy it for others to
use. You may NOT sell it or otherwise charge for its
distribution, except that recognized user groups may charge a
small fee for copying, materials, postage, etc.
If you have any suggestions, comments, or bugs to report, my address is:
Bruce F. Damkoehler
3627 Briggs Boulevard NE
Grand Rapids, MI 49505